﻿using System;
using System.Windows;
using System.Windows.Controls;
using System.ComponentModel;

using SBPweb.Forge.Controls.Silverlight;
using SBPweb.Forge.Controls.Silverlight.Utilities;

namespace SBPweb.Accelerators.StreetView.Client.BingMapsProvider.Controls
{

    public class UserControlBase : UserControl, INotifyPropertyChanged
    {

        #region Private fields

        #endregion

        #region Constructor logic

        #endregion

        #region Property accessors

        public ExtendableApplication Application
        {
            get
            {
                return System.Windows.Application.Current as ExtendableApplication;
            }
        }

        public InitialParameters ApplicationInitialParameters
        {
            get
            {
                return Application.Get<InitialParameters>("InitialParameters");
            }
        }

        #endregion

        #region Events

        public event PropertyChangedEventHandler PropertyChanged;

        #endregion

        #region Methods

        protected void RaisePropertyChanged(string propertyName)
        {
            if (PropertyChanged != null)
            {
                PropertyChanged(this, new System.ComponentModel.PropertyChangedEventArgs(propertyName));
            }
        }

        #endregion

    }

}